<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta http-equiv="X-UA-Compatible" content="IE=edge">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <select>
        <option id="a" value="一">你猜</option>
        <option id="b" value="二">我猜</option>
    </select>
    <div class="content">
        当选中select上的标签 将content中的内容设置为指定的颜色
    </div>
    <script>
     var opp=document.querySelector('.content')
     var sle=document.querySelectorAll('option')
     
    document.querySelector('select').onclick=function(){
    var res=document.querySelector('option')
    if (res=='一') {
           opp.style.color='red'}else{
            opp.style.color='yellow'
           }
    

}



    </script>
</body>
</html>